package com.tmeone.erpone.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.tmeone.erpone.entity.TPar;
import com.tmeone.erpone.entity.TProduct;
import com.tmeone.erpone.mapper.TParMapper;
import com.tmeone.erpone.service.ITParService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author YJLJBD
 * @since 2021-04-22
 */
@Service
public class TParServiceImpl extends ServiceImpl<TParMapper, TPar> implements ITParService {

    @Autowired
    TParMapper tParMapper;

    @Override
    public IPage<TPar> getPageTPar(Page<TPar> page) {
        return tParMapper.selectTParPage(page);
    }

    @Override
    public IPage<TPar> getPageTParOnTime(Page<TPar> page,String time1, String time2) {
        return tParMapper.selectTParPageOnTime(page,time1,time2);
    }

    @Override
    public void passTpar(String id) {
        tParMapper.updateTpar(id);

    }

    @Override
    public void rejectTpar(String id, String desc) {
        tParMapper.rejectTpar(id,desc);
    }


}
